[toc]
openstack rocky版手动增加一个计算节点
1.配置host解析
cat /etc/hosts <<EOF
0.0.0.11 controller
10.0.0.31 compute1
10.0.0.32 compute2
10.0.0.41 block1
10.0.0.51 object1
10.0.0.52 object2
EOF
2.配置yum源
yum -y install centos-release-openstack-rocky
yum -y install python-openstackclient
3.时间同步
1.安装chrony
yum -y install chrony
2.编辑chrony配置文件/etc/chrony.conf
/删除以下4行,指定控制节点为NTP服务器
server 0.centos.pool.ntp.org iburst
server 1.centos.pool.ntp.org iburst
server 2.centos.pool.ntp.org iburst
server 3.centos.pool.ntp.org iburst
修改为
server controller iburst
#用以下命令修改
sed -i '3,6d' /etc/chrony.conf && sed -i '3cserver controller iburst' /etc/chrony.conf
3.启动NTP服务并设置开机自启
systemctl enable chronyd && systemctl start chronyd
4.检查端口,监听udp323端口
$ netstat -nupl|grep chronyd
udp 0 0 127.0.0.1:323 0.0.0.0:* 1327/chronyd
udp6 0 0 ::1:323 :::* 1327/chronyd
5.验证,计算节点显示的是控制节点
$ chronyc sources
210 Number of sources = 1
MS Name/IP address Stratum Poll Reach LastRx Last sample
===============================================================================
^? controller 3 6 200 50 +1319ms[+1319ms] +/- 14.4s